home *** CD-ROM | disk | FTP | other *** search
/ The CICA Windows Explosion! / The CICA Windows Explosion! - Disc 2.iso / nt / ntkb.zip / NTKB.EXE / Q105 / 8 / 82.TXT < prev    next >
Text File  |  1993-11-02  |  5KB  |  136 lines

  1. DOCUMENT:Q105882  28-OCT-1993  [W_NT]
  2. TITLE   :Windows 3.1 and Windows NT Can Share Virtual Memory Space
  3. PRODUCT :Windows NT
  4. PROD/VER:3.10
  5. OPER/SYS:WINDOWS
  6. KEYWORDS:
  7.  
  8. ------------------------------------------------------------------
  9. The information in this article applies to:
  10.  
  11.  - Microsoft Windows NT operating system version 3.1
  12.  - Microsoft Windows NT Advanced Server version 3.1
  13. ------------------------------------------------------------------
  14.  
  15. SUMMARY
  16. =======
  17.  
  18. The following two methods can be used to save disk space on computers
  19. that have both Windows 3.1 and Windows NT installed:
  20.  
  21.  - Sharing the PAGEFILE.SYS file 
  22.  
  23.    -or- 
  24.  
  25.  - Creating and sharing a dedicated pagefile partition
  26.  
  27. MORE INFORMATION
  28. ================
  29.  
  30. Sharing the PAGEFILE.SYS File
  31. -----------------------------
  32.  
  33. If performance requirements allow running Windows 3.1 with a temporary
  34. swap file, Windows can be configured to use a swap file named
  35. PAGEFILE.SYS. This prevents Windows from creating the default swap
  36. file WIN386.SWP.
  37.  
  38. Because Windows (versions 3.0 and 3.1) and Windows NT both delete and
  39. recreate their virtual memory space each time they are loaded, only
  40. one file will ever exist. This method requires a temporary swap file
  41. in Windows 3.1 and that PAGEFILE.SYS be stored on a FAT partition.
  42.  
  43. To change the name of Windows 3.1 temporary swap file, do the
  44. following:
  45.  
  46. 1. Edit the SYSTEM.INI file and find the [386 Enhanced] section.
  47.  
  48. 2. Update PagingFile=c:\WIN386.SWP to PagingFile=x:\PAGEFILE.SYS,
  49.    where x is the drive letter that contains PAGEFILE.SYS.
  50.  
  51. 3. Save the file and restart Windows for the changes to take affect.
  52.  
  53. Creating and Sharing a Dedicated Paging Partition
  54. -------------------------------------------------
  55.  
  56. This method is used when Windows 3.1 needs a permanent swap file,
  57. which consists of the files 386SPART.PAR and SPART.PAR. It has four
  58. requirements: 
  59.  
  60.  - A dedicated partition 
  61.  - A FAT file system 
  62.  - A batch file (details follow)
  63.  - A requirement of exiting Windows 3.1 in the proper manner
  64.  
  65. The steps to implement this method are the following:
  66.  
  67. 1. Back everything up, if required, and repartition the hard disk
  68.    using the MS-DOS FDISK command.
  69.  
  70. 2. Create a dedicated partition large enough to hold only the Windows
  71.    swap file, 386SPART.PAR. Because Windows NT can support paging files
  72.    across multiple drives, limiting the size of the drive will not limit
  73.    the size of PAGEFILE.SYS.
  74.  
  75. 3. Restore files if necessary.
  76.  
  77. 4. Start Windows NT. In the Control Panel window, choose the System
  78.    icon, choose the Virtual Memory option button, and then change the
  79.    drive where PAGEFILE.SYS is located to the drive of the partition you
  80.    just created. Enter the size available in both the Initial Size and
  81.    Maximum Size fields. Zero out any other drives that may have also been
  82.    designated. Choose Set and OK to save changes. Quit Windows NT.
  83.  
  84. 5. Start the system into MS-DOS and delete PAGEFILE.SYS from the
  85.    paging partition.
  86.  
  87. 6. Start Windows 3.1. In the Control Panel window, choose the 386
  88.    Enhanced icon, choose the Virtual Memory option button, and then
  89.    change the drive letter to the drive of the paging partition you just
  90.    created. In the Type box, select Permanent. In the New Size box, enter
  91.    the number shown in the Space Available field. You will receive a
  92.    message stating the number is too large and to change it to a smaller
  93.    number. Accept this number by choosing the OK button. Choose Yes when
  94.    asked if you really want to make this change. Quit Windows 3.1. You
  95.    must now create a custom batch file to start Windows 3.1.
  96.  
  97. 7. Rename WIN.COM to __WIN.COM so that "WIN" no longer starts Windows.
  98.  
  99. 8. Create the following batch file using a text editor and call it
  100.    WIN.BAT. This file deletes the Windows NT paging file PAGEFILE.SYS and
  101.    runs the renamed executable file _WIN.COM to start Windows. When
  102.    Windows terminates, WIN.BAT normalizes the swap file files and deletes
  103.    them so they won't take up space when you run Windows NT.
  104.  
  105.       WIN.BAT
  106.       @ECHO OFF
  107.       IF EXIST x:\PAGEFILE.SYS DEL x:\PAGEFILE.SYS
  108.       __WIN
  109.       ATTRIB -r C:\windows\spart.par
  110.       ATTRIB -r -h -s x:\386SPART.PAR
  111.       DEL C:\windows\SPART.PAR
  112.       DEL x:\386SPART.PAR
  113.  
  114.    Where x:\ is the dedicated paging partition drive. 
  115.  
  116. Both of these methods also work for Windows for Workgroups.
  117.  
  118. Additional reference words: 3.10 WFW
  119. KBCategory:
  120. KBSubCategory: winnt
  121.  
  122. =============================================================================
  123.  
  124. THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS
  125. PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.  MICROSOFT DISCLAIMS
  126. ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES
  127. OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  IN NO
  128. EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR
  129. ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL,
  130. CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF
  131. MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE
  132. POSSIBILITY OF SUCH DAMAGES.  SOME STATES DO NOT ALLOW THE EXCLUSION
  133. OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES
  134. SO THE FOREGOING LIMITATION MAY NOT APPLY.
  135.  
  136. Copyright Microsoft Corporation 1993.